{extend name="user/index" /}
{extend name="user/check" /}
{block name="main"}

<div style="margin:100px auto;width:860px;" id="Modals-frame">
    <div class="row" style="overflow:hidden;" id="Modals-add" >
        <div class="am-u-sm-12 am-u-md-12 am-u-lg-12">
            <div class="widget am-cf">
                <div class="widget-head am-cf">
                    <div class="widget-title am-fl">编辑用户</div>
                    <div class="widget-function am-fr">
                        <a href="javascript:;" class="am-icon-cog"></a>
                    </div>
                </div>
                <div class="widget-body am-fr">

                    <form class="am-form tpl-form-border-form tpl-form-border-br" id="Modals-form" action="{:url('admin/user/doEdit',['id' => $row['id']])}" name="myform" method="post" enctype="multipart/form-data">
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">用户姓名 <span
                                    class="tpl-form-line-small-title">Name</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" placeholder={$row['name']} name="name" onblur="checkName()">
                                <small id="utab">1-12个字符。</small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">密码 <span
                                    class="tpl-form-line-small-title">Pass</span></label>
                            <div class="am-u-sm-9">
                                <input type="password" placeholder="请输入密码" name="pass" onblur="checkPass()">
                                <small id="ptab"></small>
                            </div>
                        </div>


                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">确认密码 <span
                                    class="tpl-form-line-small-title">RePass</span></label>
                            <div class="am-u-sm-9">
                                <input type="password" placeholder="请确认密码" name="repass" onblur="checkRepass()">
                                <small id="rptab"></small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户头像 <span
                                    class="tpl-form-line-small-title">Photo</span></label>
                            <div class="am-u-sm-9">
                                <img src="{$IMG_PATH}default.jpg" alt="">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户电话 <span
                                    class="tpl-form-line-small-title">Tel</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['tel']} name="tel"  onblur="checkPhone()">
                                <small id="phtab"></small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="user-intro" class="am-u-sm-3 am-form-label">激活/禁用</label>
                            <div class="am-u-sm-9">
                                <div class="tpl-switch">
                                    <input type="checkbox" class="ios-switch bigswitch tpl-switch-btn" name="status" {:$row['status']==1?'checked':'';}>
                                    <div class="tpl-switch-btn-view">
                                        <div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户年龄 <span
                                    class="tpl-form-line-small-title">Age</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['age']} name="Age" onblur="checkAge()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="user-phone" class="am-u-sm-3 am-form-label">用户性别<span class="tpl-form-line-small-title">Sex</span></label>
                            <div class="am-u-sm-9">
                                <select name="sex" id="add-admin-select" data-am-selected="{searchBox: 1}" style="display: none;">
                                    <option value='1' {:$row['sex']==1?'selected':'';}>男</option>
                                    <option value='0' {:$row['sex']==0?'selected':'';}>女</option>
                                </select>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">生日 <span
                                    class="tpl-form-line-small-title">Birthday</span></label>
                            <div class="am-u-sm-9">
                                <input type="date" placeholder={$row['birthday']} name="birthday" onblur="checkBirthday()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">省份<span
                                    class="tpl-form-line-small-title">Province</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['province']} name="province" onblur="checkProvince()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="user-phone" class="am-u-sm-3 am-form-label">婚姻状态<span class="tpl-form-line-small-title">Marrige</span></label>
                            <div class="am-u-sm-9">
                                <select name="marry" id="add-admin-select" data-am-selected="{searchBox: 1}" style="display: none;">
                                    <option value='1' {:$row['is_marry']==1?'selected':''}>已婚</option>
                                    <option value='0' {:$row['is_marry']==0?'selected':''}>未婚</option>
                                </select>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户积分 <span
                                    class="tpl-form-line-small-title">Point</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['integral']} name="integral" onblur="checkIntegral()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户邮箱 <span
                                    class="tpl-form-line-small-title">Email</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['email']} name="email" onblur="checkEmail()">
                                <small id="etab"></small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户添加时间 <span
                                    class="tpl-form-line-small-title">Addtime</span></label>
                            <div class="am-u-sm-9">
                                <input type="date" placeholder={$row['addtime']} name="addtime" onblur="checkAddtime()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label class="am-u-sm-3 am-form-label">用户经验值 <span
                                    class="tpl-form-line-small-title">Experience</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" placeholder={$row['experience']} name="experience" onblur="checkExperience()">
                            </div>
                        </div>

                        <div class="am-form-group">
                            <div class="am-u-sm-9 am-u-sm-push-3">
                                <input type="submit" class="am-btn am-btn-primary tpl-btn-bg-color-success "
                                       id="admin-add-submit"}">
                                <!--</button>-->
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>


{/block}